#ifndef MARKET_HPP_INCLUDED
#define MARKET_HPP_INCLUDED

#include <vector>

#include "item_type.hpp"

class citizen;

class barter_market {
public:
	struct offer {
		const_item_type_ptr offered, wanted;
		int quantity_offered, quantity_wanted;
		citizen* trader;
	};

	void add_offer(const offer& o);
	void resolve_market();
	void clear() { offers_.clear(); }
private:
	std::vector<offer> offers_;
};

#endif
